package com.wzc.org.mapper;

import com.wzc.basic.mapper.BaseMapper;
import com.wzc.org.domain.Employee;
import com.wzc.system.domain.Menu;
import org.apache.ibatis.annotations.Param;

import java.util.List;


/**
 * mapper接口：部门
 */
public interface EmployeeMapper extends BaseMapper<Employee> {


    void saveEmployeeRole(@Param("eid")Long id, @Param("rid")Long role_id);


    void removeEmployeeRole(Long id);

    /**
     * 查询当前登录人所有权限
     * @param id
     * @return
     */
    List<String> loadPermissionsByLogininfoId(Long id);

    /**
     * 查询当前登录人所有菜单
     * @param id
     * @return
     */
    List<Menu> loadMenusByLogininfoId(Long id);

    /**
     * 通过logininfoId 查询empl0yee
     * @param id
     * @return
     */
    Employee loadByLogininfoId(Long id);

    /**
     * 根据shopid 查询 employee
     * @param id
     * @return
     */
    List<Employee> loadByShopId(Long id);
}
